<style>
    .btn-group {
        margin-top: 15px;
    }

    .form-group {
        margin-top: 20px;
    }

    .input-group-text {
        margin-top: 15px;
    }

    .custom-select {
        width: 100px;
        height: 30px;
    }
</style>
<script src="/static/ueditor/ueditor.config.js"></script>
<script src="/static/ueditor/ueditor.all.min.js"></script>
<script src="/static/ueditor/lang/zh-cn/zh-cn.js"></script>
<div id="content-container" class="container">
    <div class="row">
        <div class="col-md-3">
            {include file="common/sidenav" /}
        </div>
        <div class="col-md-9">
            <div class="panel panel-default ">
                <div class="panel-body">
                    <!-- 带 * 号的为必填项<br/> -->

                    <form action="" method="post">
                        <input type="hidden" name="id" value="{$tie.id}"/>
                        <label class="input-group-text" for="inputGroupSelect01">请选择分类</label>
                        <select name="category_id" class="custom-select" id="inputGroupSelect01">
                            {volist name="category" id="vo"}
                            <option value="{$vo.id}" {eq name="$vo.id" value="$tie.category_id"}selected{/eq}>{$vo.name}</option>
                            {/volist}
                        </select>

                        <label class="input-group-text" style="margin-left: 40%;" for="inputGroupSelect01">请选择类型</label>
                        <select name="type" class="custom-select" id="inputGroupSelect02">
                            <option value="0" {eq name="$tie.type" value="0"}selected{/eq} >原创</option>
                            <option value="1" {eq name="$tie.type" value="1"}selected{/eq} >转载</option>
                        </select>


                        <div class="form-group">
                            <label for="exampleInputEmail1">标题</label>
                            <input type="text" value="{$tie.title}" class="form-control" name="title" id="exampleInputEmail1"
                                   aria-describedby="text">
                            <small id="text" class="form-text text-muted">请输入话题标题</small>
                        </div>

                        <div class="form-group">
                            <label>话题内容</label>
                            <textarea id="content" required=""  name="content">{$tie.content}</textarea>
                        </div>

                        <input class="btn btn-primary" type="submit" value="提交">

                    </form>
                </div>
            </div>
        </div>
    </div>


</div>
<script type="text/javascript">

    //实例化编辑器
    //建议使用工厂方法getEditor创建和引用编辑器实例，如果在某个闭包下引用该编辑器，直接调用UE.getEditor('editor')就能拿到相关的实例
    UE.getEditor('content', {initialFrameWidth: 800, initialFrameHeight: 400,});

</script>